﻿<%@ Page Title="" Language="C#" MasterPageFile="MasterPage.master" AutoEventWireup="true" CodeFile="ListagemInscritosCurso.aspx.cs" Inherits="_ListagemInscritosCurso" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
    <style type="text/css">
        .tabela2 {font: 12px tahoma, arial; margin-top:5px;}
        .tabela2 th, .tabela2 td {padding: 3px;}
    </style>

</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
<h1>Inscritos por Curso</h1>
<br />
    <table style="width:100%;">
        <tr>
            <td>
                <asp:Label ID="lblCurso" runat="server" Font-Bold="True" Font-Names="Tahoma"></asp:Label>
            </td>
        </tr>
        <tr>
            <td>
    <asp:GridView ID="GridView1" runat="server" DataSourceID="dsInscritos" 
        EnableModelValidation="True" AutoGenerateColumns="False" CellPadding="4" 
        ForeColor="#333333" GridLines="None" AllowSorting="True" 
        CssClass="tabela2" Width="494px">
        <AlternatingRowStyle BackColor="White" />
        <Columns>
            <asp:BoundField HeaderText="CPF" DataField="CPF" SortExpression="CPF" />
            <asp:BoundField HeaderText="Nome" DataField="NomeAluno" 
                SortExpression="NomeAluno" >
            <HeaderStyle HorizontalAlign="Left" />
            <ItemStyle HorizontalAlign="Left" />
            </asp:BoundField>
            <asp:BoundField HeaderText="Telefone" DataField="Telefone" 
                SortExpression="Telefone" >
            <HeaderStyle HorizontalAlign="Left" />
            <ItemStyle HorizontalAlign="Left" />
            </asp:BoundField>

            <asp:HyperLinkField DataNavigateUrlFields="CodInscrito,CPF" 
                DataNavigateUrlFormatString="DadosInscrito.aspx?cod={0}&amp;cpf={1}" 
                Text="[+]" Target="_blank" />
        </Columns>
        <EditRowStyle BackColor="#2461BF" />
        <FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
        <HeaderStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
        <PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" />
        <RowStyle BackColor="#EFF3FB" />
        <SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
    </asp:GridView>
    <asp:SqlDataSource ID="dsInscritos" runat="server" 
        ConnectionString="<%$ ConnectionStrings:conexao_intranet %>" 
        ProviderName="<%$ ConnectionStrings:conexao_intranet.ProviderName %>" SelectCommand="SELECT CamaraInscritos.CodInscrito, CamaraInscritos.CPF, CamaraInscritos.NomeAluno, CamaraInscritos.Telefone
FROM CamaraInscritosCursos INNER JOIN CamaraInscritos ON CamaraInscritosCursos.CPF = CamaraInscritos.CPF
WHERE (((CamaraInscritosCursos.CodCurso)=@codCurso))
ORDER BY CamaraInscritos.NomeAluno;
">
        <SelectParameters>
            <asp:QueryStringParameter Name="codCurso" QueryStringField="codcurso" />
        </SelectParameters>
    </asp:SqlDataSource>
            </td>
        </tr>
        <tr>
            <td>
                &nbsp;</td>
        </tr>
        <tr>
            <td align="right">
            <asp:ImageButton ID="ImageButton1" runat="server" 
                ImageUrl="../figuras/bVoltar.gif" PostBackUrl="estatisticas.aspx" />
            </td>
        </tr>
    </table>
</asp:Content>

